package com.xmtlxx.system.mapper;

import com.xmtlxx.common.annotation.DataColumn;
import com.xmtlxx.common.annotation.DataPermission;
import com.xmtlxx.common.core.domain.entity.SysCheckType;
import com.xmtlxx.common.core.mapper.BaseMapperPlus;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.xmtlxx.system.domain.bo.SysCheckTypeBo;
import com.xmtlxx.system.domain.vo.SysCheckTypeVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 检查项类型Mapper接口
 *
 * @author xmtlxx
 * @date 2022-04-26
 */
public interface SysCheckTypeMapper extends BaseMapperPlus<SysCheckTypeMapper, SysCheckType, SysCheckTypeVo> {
    /**
     * 根据条件分页查询检查项类型
     *
     * @param sysCheckTypeBo 检查项类型
     * @return Page SysCheckType
     */
    @DataPermission({
        @DataColumn(key = "tenantName", value = "s.create_by"),
        @DataColumn(key = "deptName", value = "s.create_by"),
        @DataColumn(key = "userName", value = "s.create_by")
    })
    Page<SysCheckTypeVo> selectPageSysCheckTypeList(@Param("page") Page<SysCheckType> page,@Param("sysCheckType") SysCheckTypeBo sysCheckType);

    /**
     * 查询检查项类型列表
     *
     * @param sysCheckTypeBo 检查项类型
     * @return 检查项类型集合
     */
    @DataPermission({
        @DataColumn(key = "tenantName", value = "s.create_by"),
        @DataColumn(key = "deptName", value = "s.create_by"),
        @DataColumn(key = "userName", value = "s.create_by")
    })
    List<SysCheckTypeVo> selectSysCheckTypeList(@Param("sysCheckType") SysCheckTypeBo sysCheckType);

}
